﻿<UserControl 
  x:Class="CrackNET.InjectedViewer.View.MemoryExplorer.SelectedAssemblyView"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  Background="WhiteSmoke"
  >
  <DockPanel>
    <DockPanel 
      DockPanel.Dock="Top" 
      Background="{DynamicResource PrimaryBackgroundBrush}"
      Margin="0,4,0,0" 
      MinHeight="40">
      <TextBlock
        FontSize="15" 
        FontWeight="Bold" 
        Margin="2,3"
        Text="{Binding Path=DisplayName, Mode=OneTime}" 
        TextAlignment="Left" 
        TextWrapping="Wrap"
        VerticalAlignment="Center"
        />
    </DockPanel>
    <Grid>
      <Grid.ColumnDefinitions>
        <ColumnDefinition Width="Auto" />
        <ColumnDefinition Width="*" />
      </Grid.ColumnDefinitions>
      <Grid.RowDefinitions>
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="*" />
      </Grid.RowDefinitions>

      <!-- CODE BASE -->
      <TextBlock 
        Grid.Row="0" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Code base:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="0" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=CodeBase, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- ENTRY POINT NAME -->
      <TextBlock 
        Grid.Row="1" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Entry point name:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="1" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=EntryPointName, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- FULL NAME -->
      <TextBlock 
        Grid.Row="2" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Full name:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="2" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=FullName, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- GAC -->
      <TextBlock 
        Grid.Row="3" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Loaded from GAC:"
        VerticalAlignment="Center"
        />
      <CheckBox
        Grid.Row="3" Grid.Column="1"
        HorizontalAlignment="Left"
        IsChecked="{Binding Path=GlobalAssemblyCache, Mode=OneTime}"
        IsEnabled="False"
        Margin="4,8"
        VerticalAlignment="Center"
        />

      <!-- HASH CODE -->
      <TextBlock 
        Grid.Row="4" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Hash code:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="4" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=HashCode, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- HOST CONTEXT -->
      <TextBlock 
        Grid.Row="5" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Host context:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="5" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=HostContext, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- IMAGE RUNTIME VERSION -->
      <TextBlock 
        Grid.Row="6" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Image runtime version:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="6" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=ImageRuntimeVersion, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- LOCATION -->
      <TextBlock 
        Grid.Row="7" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Location:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="7" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=Location, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- MANIFEST MODULE NAME -->
      <TextBlock 
        Grid.Row="8" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Manifest module name:"
        VerticalAlignment="Center"
        />
      <TextBox
        Grid.Row="8" Grid.Column="1"
        HorizontalAlignment="Left"
        IsReadOnly="True"
        Margin="4,8"
        Text="{Binding Path=ManifestModuleName, Mode=OneTime}"
        VerticalAlignment="Center"
        />

      <!-- REFLECTION ONLY -->
      <TextBlock 
        Grid.Row="9" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Reflection only:"
        VerticalAlignment="Center"
        />
      <CheckBox
        Grid.Row="9" Grid.Column="1"
        HorizontalAlignment="Left"
        IsChecked="{Binding Path=ReflectionOnly, Mode=OneTime}"
        IsEnabled="False"
        Margin="4,8"      
        VerticalAlignment="Center"
        />

      <!-- REFERENCED ASSEMBLIES -->
      <TextBlock 
        Grid.Row="10" Grid.Column="0"
        FontWeight="SemiBold"
        HorizontalAlignment="Right"
        Margin="4,8"
        Text="Referenced assemblies:"
        VerticalAlignment="Top"
        />
      <ScrollViewer 
        Grid.Row="10" Grid.Column="1"
        HorizontalAlignment="Left"
        Margin="4,8" 
        VerticalAlignment="Top"
        VerticalScrollBarVisibility="Auto"
        >
        <ItemsControl 
          Background="White" 
          ItemsSource="{Binding Path=ReferencedAssemblyNames, Mode=OneTime}" 
          />
      </ScrollViewer>
    </Grid>
  </DockPanel>
</UserControl>